import request from '@/utils/request'

// 查询环境配置列表
export function listEnviroment(query) {
  return request({
    url: '/training/enviroment/list',
    method: 'get',
    params: query
  })
}

// 查询环境配置详细
export function getEnviroment(id) {
  return request({
    url: '/training/enviroment/' + id,
    method: 'get'
  })
}

// 新增环境配置
export function addEnviroment(data) {
  return request({
    url: '/training/enviroment',
    method: 'post',
    data: data
  })
}

// 修改环境配置
export function updateEnviroment(data) {
  return request({
    url: '/training/enviroment',
    method: 'put',
    data: data
  })
}

// 删除环境配置
export function delEnviroment(id) {
  return request({
    url: '/training/enviroment/' + id,
    method: 'delete'
  })
}
